home *** CD-ROM | disk | FTP | other *** search
/ Personal Computer World 2009 February / PCWFEB09.iso / Software / Linux / SLAX 6.0.8 / slax-6.0.8.iso / slax / base / 006-devel.lzm / usr / include / oss-redir.h < prev    next >
Encoding:
C/C++ Source or Header  |  2008-09-18  |  2.1 KB  |  59 lines

  1. #ifndef __OSS_REDIR_H
  2. /*
  3.  *  OSS Redirector
  4.  *  Copyright (c) by Jaroslav Kysela <perex@perex.cz>
  5.  *
  6.  *
  7.  *   This program is free software; you can redistribute it and/or modify
  8.  *   it under the terms of the GNU General Public License as published by
  9.  *   the Free Software Foundation; either version 2 of the License, or
  10.  *   (at your option) any later version.
  11.  *
  12.  *   This program is distributed in the hope that it will be useful,
  13.  *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  14.  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  15.  *   GNU General Public License for more details.
  16.  *
  17.  *   You should have received a copy of the GNU General Public License
  18.  *   along with this program; if not, write to the Free Software
  19.  *   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
  20.  *
  21.  */
  22.  
  23. #include <sys/select.h>
  24. #include <sys/types.h>
  25.  
  26. struct pollfd;
  27.  
  28. #define OSS_WAIT_EVENT_READ    (1<<0)
  29. #define OSS_WAIT_EVENT_WRITE    (1<<1)
  30. #define OSS_WAIT_EVENT_ERROR    (1<<2)
  31.  
  32. #ifdef __cplusplus
  33. extern "C" {
  34. #endif
  35.  
  36. extern int oss_pcm_open(const char *pathname, int flags, ...);
  37. extern int oss_pcm_close(int fd);
  38. extern int (*oss_pcm_nonblock)(int fd, int nonblock);
  39. extern ssize_t (*oss_pcm_read)(int fd, void *buf, size_t count);
  40. extern ssize_t (*oss_pcm_write)(int fd, const void *buf, size_t count);
  41. extern void * (*oss_pcm_mmap)(void *start, size_t length, int prot, int flags, int fd, off_t offset);
  42. extern int (*oss_pcm_munmap)(void *start, size_t length);
  43. extern int (*oss_pcm_ioctl)(int fd, unsigned long int request, ...);
  44. extern int (*oss_pcm_select_prepare)(int fd, int fmode, fd_set *readfds, fd_set *writefds, fd_set *exceptfds);
  45. extern int (*oss_pcm_select_result)(int fd, fd_set *readfds, fd_set *writefds, fd_set *exceptfds);
  46. extern int (*oss_pcm_poll_fds)(int fd);
  47. extern int (*oss_pcm_poll_prepare)(int fd, int fmode, struct pollfd *ufds);
  48. extern int (*oss_pcm_poll_result)(int fd, struct pollfd *ufds);
  49.  
  50. extern int oss_mixer_open(const char *pathname, int flags, ...);
  51. extern int oss_mixer_close(int fd);
  52. extern int (*oss_mixer_ioctl)(int fd, unsigned long int request, ...);
  53.  
  54. #ifdef __cplusplus
  55. }
  56. #endif
  57.  
  58. #endif /* __OSS_REDIR_H */
  59.